package com.credit.filter;

import java.io.IOException;

import javax.servlet.Filter;
import javax.servlet.FilterChain;
import javax.servlet.FilterConfig;
import javax.servlet.ServletException;
import javax.servlet.ServletRequest;
import javax.servlet.ServletResponse;

import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;

import com.credit.context.CreditServletContext;



/**
 * 垃圾回收filter
 * @author 
 *
 */
public class GCFilter implements Filter {
	private static Log log = LogFactory.getLog(GCFilter.class);

	public void destroy() {
		
	}

	public void doFilter(ServletRequest req, ServletResponse res,
			FilterChain chain) throws IOException, ServletException {
		chain.doFilter(req, res);
		CreditServletContext.remove();
		
	}

	public void init(FilterConfig arg0) throws ServletException {
		
		
	}

}
